package com.kkwrite.regimen.common.entity.dto.order;

import com.kkwrite.regimen.common.constant.OrderStatusEnum;

import java.io.Serializable;

/**
 * Created by lisha on 2018/8/13 16:29.
 *
 * @author lisha
 */
public class OrderChangePayStatusInDTO implements Serializable {
    private static final long serialVersionUID = -5222899981770032401L;

    private String orderCode;
    private Short payStatus;

    public boolean isEmpty() {
        return orderCode == null || orderCode.trim().isEmpty() || payStatus == null
                || (!payStatus.equals(OrderStatusEnum.PayStatusEnum.UNPAID.getPayStatus())
                        && !payStatus.equals(OrderStatusEnum.PayStatusEnum.PAID.getPayStatus()));
    }

    public String getOrderCode() {
        return orderCode;
    }

    public void setOrderCode(String orderCode) {
        this.orderCode = orderCode;
    }

    public Short getPayStatus() {
        return payStatus;
    }

    public void setPayStatus(Short payStatus) {
        this.payStatus = payStatus;
    }

    @Override
    public String toString() {
        return "OrderChangePayStatusInDTO{" +
                "orderCode='" + orderCode + '\'' +
                ", payStatus=" + payStatus +
                '}';
    }
}
